Optimal. Leaf size=12 \[ \tan ^{-1}(x)-\frac{1}{x^2+1} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0071213, antiderivative size = 22, normalized size of antiderivative = 1.83, number of steps used = 3, number of rules used = 3, integrand size = 16, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.188, Rules used = {27, 723, 203} \[ \tan ^{-1}(x)-\frac{(1-x) (x+1)}{2 \left (x^2+1\right )} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 27
Rule 723
Rule 203
Rubi steps
\begin{align*} \int \frac{1+2 x+x^2}{\left (1+x^2\right )^2} \, dx &=\int \frac{(1+x)^2}{\left (1+x^2\right )^2} \, dx\\ &=-\frac{(1-x) (1+x)}{2 \left (1+x^2\right )}+\int \frac{1}{1+x^2} \, dx\\ &=-\frac{(1-x) (1+x)}{2 \left (1+x^2\right )}+\tan ^{-1}(x)\\ \end{align*}
Mathematica [A] time = 0.0122203, size = 12, normalized size = 1. \[ \tan ^{-1}(x)-\frac{1}{x^2+1} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.046, size = 13, normalized size = 1.1 \begin{align*} - \left ({x}^{2}+1 \right ) ^{-1}+\arctan \left ( x \right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 1.46191, size = 16, normalized size = 1.33 \begin{align*} -\frac{1}{x^{2} + 1} + \arctan \left (x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 0.957922, size = 50, normalized size = 4.17 \begin{align*} \frac{{\left (x^{2} + 1\right )} \arctan \left (x\right ) - 1}{x^{2} + 1} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 0.102492, size = 8, normalized size = 0.67 \begin{align*} \operatorname{atan}{\left (x \right )} - \frac{1}{x^{2} + 1} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.17692, size = 16, normalized size = 1.33 \begin{align*} -\frac{1}{x^{2} + 1} + \arctan \left (x\right ) \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]